package com.itheima.springboot02_demo01.config;

import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@EnableConfigurationProperties(SMSConfigProperties.class)
public class SMSConfiguration {
    @Bean
    public SMSClient smsClient(SMSConfigProperties smsConfigProperties){
        /*SMSConfigProperties smsConfigProperties=new SMSConfigProperties();
        smsConfigProperties.setAccessKeyId("LTAI5t9d6ZFeKq6d56UWnvU3");
        smsConfigProperties.setAccessSecret("JMNItvcvGpydwC57wfN4pIUlqkUY9D");
        smsConfigProperties.setSignName("黑马健康");
        smsConfigProperties.setTemplateCode("SMS_171111537");*/

        return new SMSClient(smsConfigProperties);
    }


}
